Skip to content

lnk_pipeline_run: produce streams_access regardless of mapping_code#219

Merged
NewGraphEnvironment merged 4 commits into
mainfrom
218-lnk-pipeline-run-produce-streams-access-
Jun 9, 2026
Merged

lnk_pipeline_run: produce streams_access regardless of mapping_code#219
NewGraphEnvironment merged 4 commits into
mainfrom
218-lnk-pipeline-run-produce-streams-access-

Conversation

@NewGraphEnvironment

Copy link
Copy Markdown
Owner

Summary

  • lnk_pipeline_run() now builds and persists <persist_schema>.streams_access (+ access_<sp>) regardless of the mapping_code flag. The access build (lnk_presence -> pre-persist -> lnk_barriers_views -> lnk_pipeline_access) moves out of the if (isTRUE(mapping_code)) block to run unconditionally; only the mapping_code token assembly (lnk_mapping_code) stays gated.
  • Access is foundational — mapping_code depends on it, not the reverse — so habitat-only callers (mapping_code = FALSE: data-raw/wsg_pipeline_run.R, lnk_compare_wsg(mapping_code = FALSE)) now also emit streams_access.
  • No persist change required: lnk_pipeline_persist() already probes information_schema for streams_access and streams_mapping_code independently and copies whichever working tables exist.

Related Issues

Test plan

  • devtools::test() green — test-lnk_pipeline_run.R 20 PASS (rewritten composition test for the new call order + new gating test asserting access builds for both mapping_code values while lnk_mapping_code is gated)
  • /code-check clean (3 rounds, 0 findings)
  • tools::buildVignettes(dir = ".", tangle = FALSE, clean = TRUE) exits 0
  • lintr introduces no new lint class

Notes

The mapping_code = TRUE execution order (pre-persist -> barriers_views -> access -> mapping_code -> final persist) is byte-identical to v0.42.0, so the cached vignette parity (99.04% BT) is unchanged. The pre-persist (step 0) moves out alongside access because lnk_barriers_views() defaults to reading <persist_schema>.barriers (cross-WSG dam visibility, #196), so the current WSG's barriers must be persisted before the views are built. Version bump 0.42.0 -> 0.43.0 (minor — output behavior changes for existing habitat-only callers; signature unchanged).

Generated with Claude Code

NewGraphEnvironment and others added 4 commits June 8, 2026 22:15
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
lnk_pipeline_run() now builds and persists streams_access regardless of
mapping_code. lnk_presence, the pre-persist, lnk_barriers_views, and
lnk_pipeline_access move out of the `if (isTRUE(mapping_code))` block;
only lnk_mapping_code (token assembly) stays gated. Access is
foundational — mapping_code depends on it — so habitat-only callers
(mapping_code = FALSE) now also emit <persist_schema>.streams_access.

No persist change needed: lnk_pipeline_persist already probes for
streams_access and streams_mapping_code independently.

Tests: rewrite the composition test for the new call order (presence ->
pre-persist -> barriers_views -> access -> final persist); add a test
asserting access builds for both mapping_code values while lnk_mapping_code
is gated; add access-path mocks to the dams + cleanup tests.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
NEWS entry + version bump for #218 (streams_access built regardless of
mapping_code. Minor bump: output behavior changes for habitat-only
callers (new streams_access emitted) though the signature is unchanged.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
EOF
)
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@NewGraphEnvironment NewGraphEnvironment merged commit 29e3e92 into main Jun 9, 2026
1 check passed
@NewGraphEnvironment NewGraphEnvironment deleted the 218-lnk-pipeline-run-produce-streams-access- branch June 9, 2026 05:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

lnk_pipeline_run: produce streams_access regardless of mapping_code

1 participant